﻿using JE.MicroMVVM.Example.Contracts;
using JE.MicroMVVM.Example.DataModels;
using MicroMVVM;

namespace JE.MicroMVVM.Example.Services.Runtime
{
    [ExportService(ServiceType.Runtime, typeof (IServiceThree))]
    public class ServiceThreeRuntime : IServiceThree
    {
        private readonly IServiceOne _serviceOne;
        private readonly IServiceTwo _serviceTwo;

        public ServiceThreeRuntime(IServiceOne serviceOne, IServiceTwo serviceTwo)
        {
            _serviceOne = serviceOne;
            _serviceTwo = serviceTwo;
        }

        public DataModelThree GetModel()
        {
            return new DataModelThree()
                       {
                           Title = "This is runtime service three DataModelThree"
                       };
        }
    }
}